﻿@model ISS.Models.Users
<!DOCTYPE html>
<!-- saved from url=(0030)http://utopiaadmin.themio.net/ -->
<html lang="en">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta charset="utf-8">
    <title>Utopia, from Themio</title>
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="A complete admin panel theme">
    <meta name="author" content="theemio">
    <link href="@Url.Content("~/Content/Css/utopia-white.css")" rel="stylesheet">
    <link href="@Url.Content("~/Content/Css/utopia-responsive.css")" rel="stylesheet">
    <link href="@Url.Content("~/Content/Css/validationEngine.jquery.css")" rel="stylesheet">
    <link href="http://utopiaadmin.themio.net/less/index.less" rel="stylesheet/less">
    <!--[if lt IE 9]><script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
    <link rel="stylesheet" type="text/css" href="chrome-extension://lfjamigppmepikjlacjdpgjaiojdjhoj/css/menu.css">
</head>
<body>
    <div class="container-fluid">
        <div class="row-fluid">
            <div class="span12">
                <div class="utopia-login-message">
                    <h1>
                        Welcome to ISS</h1>
                    <p>
                        Sign in to get access</p>
                </div>
            </div>
        </div>
        <div class="row-fluid">
            <div class="span12">
                <div class="row-fluid">
                    <div class="span6">
                        <div class="utopia-login">
                            @if (Session["User"] != null)
                            {
                                <h1>Da dang nhap</h1>
                            }
                            else
                            {
                                <h1>
                                Đăng ký tài khoản</h1>
                                using (Html.BeginForm("Register", "Home", FormMethod.Post, new { @class = "utopia" }))
                                {

                                    @Html.LabelFor(m => m.UserName);
                                    @Html.TextBoxFor(m => m.UserName);
                                    @Html.ValidationMessageFor(m => m.UserName);
                                               
                                    @Html.LabelFor(m => m.Password);
                                    @Html.PasswordFor(m => m.Password);                                  
                                    @Html.ValidationMessageFor(m => m.Password);                                
                                               
                                    @Html.LabelFor(m => m.ConfirmPassword);
                                    @Html.PasswordFor(m => m.ConfirmPassword);                                  
                                    @Html.ValidationMessageFor(m => m.ConfirmPassword);                                

                                    @Html.LabelFor(m => m.Email);
                                    @Html.TextBoxFor(m => m.Email);
                                    @Html.ValidationMessageFor(m => m.Email);                                       
                                
                                    @Html.LabelFor(m => m.Phone);
                                    @Html.TextBoxFor(m => m.Phone);
                                    @Html.ValidationMessageFor(m => m.Phone);                               
                                      <ul>
                                            <li>
                                                <input type="submit" name="btnSubmit" value="Register" class="btn span4" />
                                            </li>
                                        </ul>               
                                    
                                }
                            }
                    </div>
                    </div>
                    <div class="span6">
                        <div class="utopia-login">
                            <h1>
                                Đăng nhập</h1>
                                @using (Html.BeginForm("Login", "Home", FormMethod.Post, new { @class = "utopia" }))
                                {
                                    @Html.LabelFor(m => m.UserName);
                                    @Html.TextBoxFor(m => m.UserName, new { @class = "span12 utopia-fluid-input validate[required]" });
                                    @Html.LabelFor(m => m.Password);
                                    @Html.PasswordFor(m => m.Password, new { @class = "span12 utopia-fluid-input validate[required]" });
                                            <ul>
                                                <li>
                                                    <input type="submit" class="btn span4" value="Login" name="btnSubmit"><div class="pull-right">
                                                        <input type="checkbox">
                                                        Remember me!</div>
                                                </li>
                                            </ul>
                                <label>
                                    <a href="http://utopiaadmin.themio.net/#">Can't access your account?</a></label>
                                }
                            
                        </div>
                    </div>
                
            </div>
        </div>
    </div>
    <script type="text/javascript" src="@Url.Content("~/Scripts/jquery.min.js")"></script>
    <script type="text/javascript" src="@Url.Content("~/Scripts/utopia.js")"></script>
    <script type="text/javascript" src="@Url.Content("~/Scripts/jquery.validationEngine.js")"></script>
    <script type="text/javascript" src="@Url.Content("~/Scripts/jquery.validationEngine-en.js")"></script>
    <script type="text/javascript">        jQuery(function () { jQuery(".utopia").validationEngine("attach", { promptPosition: "topLeft", scroll: false }) });</script>
</body>
</html>


@{
    Layout = "";
    ViewBag.Title = "Index";
}

@{
    if (ViewBag.Successful != null)
    {
        if (ViewBag.Successful == 1)
        {
            <script>alert('Register successfully')</script>
        }
        else
        {
            <script>alert('Register unsuccessfully')</script>
        }
    }
}
